/*
 * Settings for Pinyomi system
 *
 * ZhihuiJin <zhihuijin@gmail.com>
 * vim: ts=4 sw=4 sts=4 et tw=78:
 * Sat Sep 15 16:22:13 JST 2007
 */ 
package jp.ac.utokyo.pinyomi;

import java.io.Serializable;

public class Settings implements Serializable {

	private static final long serialVersionUID = 1L;

    /** Log-Probability for unknown item */
    public static final int nullLogProb = -40;

    /** data directory */
    public static String DataDir;

    /** Chinese word frequency counts in corups */
    public static String ChWordCorpusProbs;

    /** Japanese word frequency counts in corups */
    public static String JpWordCorpusProbs;

    /** Estimated Chinese word probability counts in corups */
    public static String ChWordCorpusCounts;

    /** Estimated Japanese word probability counts in corups */
    public static String JpWordCorpusCounts;

    /** Japanese Kanji kana reading counts distribution table */
    public static String KanjiReadingCounts;

    /** Chinese GBK Hanzi pinyin reading table */
    public static String GBKPinyinTable;

    /** Kanji/Hanzi cognate mapping table */
    public static String KanjiHanziCognates ;

    /** Kanji-to-Hanzi transliteration table */
    public static String KanjiHanziShapeMapping;

    /** Hanzi-to-Kanji transliteration table */
    public static String HanziKanjiShapeMapping;

    /** Chinese dictionary data for Lucene */
    public static String ChLuceneData;

    /** Japanese dictionary data for Lucene */
    public static String JpLuceneData;
    
    /** Chinese dictionary Index for Lucene */
    public static String ChLuceneIndex;
    
    /** Japanese dictionary Index for Lucene */
    public static String JpLuceneIndex;
    
    /**
     * Given tomcat home dir, then decied data files' path.
     * @param root Tomcat home dir.
     */
    public static void Sets(String root){
    	DataDir = root + "/data/";
    	ChWordCorpusProbs  = DataDir + "corpus/ch_word_corpus_probs";
    	JpWordCorpusProbs  = DataDir + "corpus/jp_word_corpus_probs";
    	ChWordCorpusCounts = DataDir + "corpus/ch_word_corpus_counts";
    	KanjiReadingCounts = DataDir + "corpus/kanji_reading_counts";
    	GBKPinyinTable     = DataDir + "tables/gbk_pinyin_table";
    	KanjiHanziCognates = DataDir + "tables/kanji_hanzi_cognates";
    	KanjiHanziShapeMapping= DataDir + "tables/kanji_hanzi_shape_mapping";
    	HanziKanjiShapeMapping= DataDir + "tables/hanzi_kanji_shape_mapping";
    	ChLuceneData = DataDir + "lucene_data/dictData/ch/ch_fields_edict.txt";
    	JpLuceneData = DataDir + "lucene_data/dictData/jp/jp_fields_edict.txt";
    	ChLuceneIndex = DataDir + "lucene_data/dictIndex/ch";
    	JpLuceneIndex = DataDir + "lucene_data/dictIndex/jp";
    }
};
